package com.xuecheng.api.cms;

import com.xuecheng.framework.domain.cms.CmsPage;
import com.xuecheng.framework.domain.cms.request.QueryPageRequest;
import com.xuecheng.framework.domain.cms.response.CmsPageResult;
import com.xuecheng.framework.domain.cms.response.CmsPostPageResult;
import com.xuecheng.framework.model.response.QueryResponseResult;
import com.xuecheng.framework.model.response.ResponseResult;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;

/*
 * 这个接口提供页面的增删改查
 */
@Api(value="cms页面管理接口",description = "cms页面管理接口，提供页面的增、删、改、查",tags= {"CMS页面管理"})
public interface CmsPageControllerApi {
    
    //分页查询
    @ApiOperation("分页查询列表页面")
    @ApiImplicitParams({
        @ApiImplicitParam(name="page",value="页码",required = true,paramType = "path",dataType = "int"),
        @ApiImplicitParam(name="size",value="每页记录条数",required = true,paramType = "path",dataType = "int")
    })
    
    QueryResponseResult findList(int page,int size,QueryPageRequest queryPageRequest);
    
    @ApiOperation("页面新增")
    CmsPageResult add(CmsPage cmsPage);
    
    @ApiOperation("根据id查询页面信息")
    CmsPage findById(String id);
    
    @ApiOperation("修改页面")
    CmsPageResult edit(String id,CmsPage cmsPage);
    
    @ApiOperation("删除页面")
    ResponseResult delete(String id);
    
    @ApiOperation("页面发布")
    ResponseResult post(String pageId);
    
    @ApiOperation("保存页面")
    CmsPageResult save(CmsPage cmsPage);
    
    @ApiOperation("页面一键发布")
    CmsPostPageResult postPageQuick(CmsPage cmsPage);
    
    
    
        
}
